@isTest
private class RejectGoodWebServiceTest{
    static testMethod void testMethod1 (){
        Account acc1 = TestUtils.createAccount();
        insert acc1;
        
        // 创建出库单
        ExWarehouse__c e = new ExWarehouse__c ();
        e.Account__c = acc1.Id;
        insert e ;
        // 创建退货单
        ExWarehouse__c ex = new ExWarehouse__c();
        ex.Account__c = acc1.Id;
        ex.isreturnorder__c = true;
        ex.returnrelationexhouse__c = e.Id;
        ex.returnTransportFee__c = 10;
        insert ex ;
        // 创建退货明细单
        ExWarehouse_Detail__c ed = new ExWarehouse_Detail__c();
        ed.ExWarehouse__c = ex.Id;
        ed.ReturnNum__c = 10;
        insert ed;
        System.assertEquals('success', RejectGoodWebService.postRejectOrder(ex.Id));

    }
}